// ===================================
// <copyright>
// This file is part of LABSMFController.
//
//    LABSMFController is free software: you can redistribute it and/or modify
//    it under the terms of the GNU General Public License as published by
//    the Free Software Foundation, either version 3 of the License, or
//    (at your option) any later version.
//
//    LABSMFController is distributed in the hope that it will be useful,
//    but WITHOUT ANY WARRANTY; without even the implied warranty of
//    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
//    GNU General Public License for more details.
//
//    You should have received a copy of the GNU General Public License
//    along with LABSMFController.  If not, see <http://www.gnu.org/licenses/>.
//    Copyright 2011 David Bakker
//
//</copyright>
// <author>David Bakker</author>
// <email>mailto:DavidFBakker@gmail.com</email>
// <created>Saturday, May 07, 2011</created>
// <lastedit>Saturday, May 07, 2011</lastedit>
// ===================================

namespace LABSMFController.LABS.Classses
{
    

    #region Nested type: Location

    public static class Location
    {

        public static string GetLocationClientOutPut()
        {
            string ret = "HEADER:Locations:LocationID,Name;";
            for (int c = 0; c < Location.Names.Length; c++)
            {
                ret = ret + "\r\n" + c + "," + Location.Names[c] + ";";
            }
            return ret;
        }

        public const int HLT = 0;
        public const int MLT = 1;
        public const int BK = 2;
        public const int Max = 3;

        public static string[] Names = new string[3];

        static Location()
        {
            Setup();
        }


        public static void Setup()
        {
            Names = new string[Max];
            Names[HLT] = "HLT";
            Names[MLT] = "MLT";
            Names[BK] = "BK";
        }

        public static int GetID(string name)
        {
            for (int index = 0; index < Names.Length; index++)
                if (Names[index].Equals(name)) return index;

            return -1;
        }
    }

    #endregion
}